Long documents usually have complex document structures, via which users may rapidly find contents they desire to consult. In particular, documents such as laws, technical standards and contracts might comprise dozens of chapters and hundreds of articles. If a user cares only about a certain article in a given chapter of a document, without the assistance of a document structure, the user has to browse hundreds and even thousands of pages to find desired contents. The heavy workload is well imaginable.
Existing document editing tools offer a document structure setting function. The user may use these document editing tools to set a corresponding document structure for different parts of a document when editing the document. For example, a “title” level document structure may be set with respect to the title of the document, and a “chapter” level document structure may be set with respect to the first chapter in the document, etc. In other words, the user may set different levels of titles in the document, and further set other levels in each chapter. However, since many documents like laws and technical standards were promulgated years ago, they may only exist in printed paper versions instead of electronic versions, or even if an electronic version exists, the electronic version might only be in plain text and include no document structure information.
Further, it should be understood that a document structure may be manually extracted from a short document; however, generating a document structure for a long document that has been repeatedly modified over the years and includes hundreds and even thousands of pages becomes an issue.